#include "AudioManager.h"

namespace mpgl_engine{ namespace application { namespace audio {

	AudioManager::AudioManager(GlConsole* console)
	{
		m_console = console;
		if (m_console != NULL){
			string msg = AudioDefines::CONSOLE_MSG_PREFIX;
			msg += "Constructed";
			m_console->WriteMessage(msg);
		}
	}

	AudioManager::~AudioManager()
	{
		//if(m_engine)
			//m_engine->drop();
		if (m_console != NULL)
		{
			string msg = AudioDefines::CONSOLE_MSG_PREFIX;
			msg += "Destructed!";
			m_console->WriteMessage(msg);
		}
	}

	void AudioManager::Initialize()
	{
		if (m_console != NULL){
			string msg = AudioDefines::CONSOLE_MSG_PREFIX; 
			msg += "Audio Disabled!";
			m_console->WriteMessage(msg);}
	}

	void AudioManager::Uninitialize()
	{
	}

	void AudioManager::Update()
	{

	}

	void AudioManager::AudioTest(bool looped)
	{
		//if (m_engine){
			//m_engine->play2D("Resources/Audio/sail.ogg",true);	
			//printf("> Starting Audio Test!\n");
		//}
	}

	void AudioManager::InitializeEngine()
	{
		//if (!m_engine)
			//m_engine = createIrrKlangDevice();
	}
}}}